/**
 * File: NodePartialStatistic.java
 * Created by: mhaimel
 * Created on: Mar 29, 2010
 * CVS:  $Id: NodePartialStatistic.java 1.0 Mar 29, 2010 10:14:35 AM mhaimel Exp $
 */
package uk.ac.ebi.curtain.model.graph.curtain.filter;

import uk.ac.ebi.curtain.model.graph.Node;
import uk.ac.ebi.curtain.model.graph.NodeEdge;
import uk.ac.ebi.curtain.model.graph.curtain.ContigInfo;
import uk.ac.ebi.curtain.model.graph.curtain.ReadWrapper;

/**
 * @author mhaimel
 *
 */
public class NodePartialStatistic extends AbstractStatistic<Node<ContigInfo, ReadWrapper>> {

	public NodePartialStatistic(Integer categories) {
		super(categories);
	}

	@Override
	protected Integer getValue(Node<ContigInfo, ReadWrapper> node, int cat) {
		for(NodeEdge edge : NodeEdge.values()){
			Integer val = node.getValue().getPartial(cat, edge);
			if(val > 0){
				addValue(cat, val);
			}
		}
		return null;
	}

}
